using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public abstract class GUIControl : MonoBehaviour
{
    //位置信息
    public GUIPosition guiPos;
    //显示内容
    public GUIContent content;
    //自定义样式
    public GUIStyle style;
    //样式开关
    public E_Style_OnOff styleSwitch = E_Style_OnOff.Off;

    //提供给外部绘制GUI的方法
    public void DrawGUI()
    {
        switch (styleSwitch)
        {
            case E_Style_OnOff.On:
                StyleOnDraw();
                break;
            case E_Style_OnOff.Off:
                StyleOffDraw();
                break;
        }
    }

    protected abstract void StyleOnDraw();
    protected abstract void StyleOffDraw();
}
